package model

import (
	"time"
)

type AuOrder struct {
	OrderId                  int       `xorm:"not null pk autoincr INT(10)"`
	OrderNo                  string    `xorm:"not null index VARCHAR(20)"`
	Rank                     int       `xorm:"not null index INT(10)"`
	EmpId                    int       `xorm:"not null INT(10)"`
	CarId                    int       `xorm:"not null index INT(10)"`
	SceneId                  int       `xorm:"not null index INT(10)"`
	Status                   int       `xorm:"not null default 1 index INT(10)"`
	BidStartTime             time.Time `xorm:"not null DATETIME"`
	BiddingStartTime         time.Time `xorm:"not null index DATETIME"`
	BiddingEndTime           time.Time `xorm:"not null index DATETIME"`
	EstElapsedTime           int       `xorm:"not null INT(10)"`
	ActElapsedTime           int       `xorm:"not null INT(10)"`
	TradeTime                time.Time `xorm:"not null DATETIME"`
	FailType                 int       `xorm:"not null index(idx_fail_type) SMALLINT(3)"`
	Commision                float64   `xorm:"not null DOUBLE(10,2)"`
	TransferFee              float64   `xorm:"not null DOUBLE(10,2)"`
	TransferType             int       `xorm:"not null default 0 TINYINT(1)"`
	DeliverType              int       `xorm:"not null SMALLINT(3)"`
	BidStartPrice            float64   `xorm:"not null DOUBLE(10,2)"`
	BidBestPrice             float64   `xorm:"not null default 0.00 DOUBLE(10,2)"`
	BiddingBestPrice         float64   `xorm:"not null default 0.00 DOUBLE(10,2)"`
	BidBestDealerId          int       `xorm:"not null default 0 INT(10)"`
	Coupon                   int       `xorm:"not null INT(10)"`
	BiddingBestDealerId      int       `xorm:"not null default 0 INT(10)"`
	CompanySubsidies         float64   `xorm:"not null default 0.00 DOUBLE(10,2)"`
	SuccessPrice             float64   `xorm:"not null DOUBLE(10,2)"`
	SuccessDealerId          int       `xorm:"not null INT(10)"`
	DealerConfirmStatus      int       `xorm:"not null default 1 SMALLINT(3)"`
	IsSelfConfirm            int       `xorm:"not null default 0 TINYINT(1)"`
	RemarkFail               string    `xorm:"TEXT"`
	RemarkReject             string    `xorm:"not null TEXT"`
	PayType                  int       `xorm:"not null SMALLINT(3)"`
	OwnerConfirmServiceId    int       `xorm:"not null INT(10)"`
	DealerConfirmServiceId   int       `xorm:"not null INT(10)"`
	UnsoldServiceId          int       `xorm:"not null INT(10)"`
	ArbitrateServiceId       int       `xorm:"not null INT(10)"`
	IsSignTracing            int       `xorm:"not null TINYINT(1)"`
	DealerPayMode            int       `xorm:"not null default 1 TINYINT(1)"`
	DealerPayStatus          int       `xorm:"not null default 0 TINYINT(4)"`
	LastTime                 time.Time `xorm:"not null DATETIME"`
	CreateTime               time.Time `xorm:"not null DATETIME"`
	FirstMoney               float64   `xorm:"not null DOUBLE(10,2)"`
	TailMoney                float64   `xorm:"not null DOUBLE(10,2)"`
	FirstPayStatus           int       `xorm:"not null TINYINT(1)"`
	ConsultIncrease          float32   `xorm:"not null default 0.00 FLOAT(10,2)"`
	IsConsult                int       `xorm:"not null TINYINT(1)"`
	ReservePrice             float64   `xorm:"not null DOUBLE(10,2)"`
	ShowReservePrice         int       `xorm:"default 0 TINYINT(1)"`
	IsTimingOrder            int       `xorm:"not null TINYINT(1)"`
	IsRecommend              int       `xorm:"not null default 1 TINYINT(1)"`
	Compensation             float32   `xorm:"not null default 0.00 FLOAT(10,2)"`
	Depreciate               float32   `xorm:"not null default 0.00 FLOAT(10,2)"`
	ReturnCheckStatus        int       `xorm:"not null default 0 TINYINT(1)"`
	CheckCarStatus           int       `xorm:"not null default 0 SMALLINT(3)"`
	IsOwnerIssue             int       `xorm:"not null default 0 SMALLINT(3)"`
	IsDealerIssue            int       `xorm:"not null default 0 SMALLINT(3)"`
	DealerIssueStatus        int       `xorm:"not null default 0 TINYINT(1)"`
	BusinessVerifyStatus     int       `xorm:"not null default 0 TINYINT(1)"`
	PlatformConfirmServiceId int       `xorm:"not null default 0 INT(10)"`
	PlatformConfirmIncrease  float32   `xorm:"not null default 0.00 FLOAT(10,2)"`
	ConfirmType              int       `xorm:"not null default 0 index(idx_fail_type) TINYINT(1)"`
	IsLock                   int       `xorm:"not null TINYINT(4)"`
	IsOtherChannelDeal       int       `xorm:"default 0 TINYINT(1)"`
	Refer                    int       `xorm:"default 0 TINYINT(1)"`
}
